package com.exercise.api.feign;

import com.exercise.commons.param.PaymentParam;
import com.exercise.commons.vo.Result;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestBody;

import java.util.Map;

@FeignClient(name = "DeWu-storage-service",contextId = "payApi")
public interface PayApiFeign {

    /**
     * 支付订单
     *
     * @param paymentParam 支付所需参数
     * @return Result
     */
    @GetMapping("/pay/payOrder")
    Result payOrder(@RequestBody PaymentParam paymentParam);

    /**
     * 支付宝回调接口
     *
     * @param mapParam 支付宝参数
     * @return Result
     */
    @GetMapping("/pay/alipayCallBack")
    Result alipayCallBack(@RequestBody Map<String, String> mapParam);
}
